Integrand size = 10, antiderivative size = 31 \[ \int x \cot ^2(a+b x) \, dx=-\frac {x^2}{2}-\frac {x \cot (a+b x)}{b}+\frac {\log (\sin (a+b x))}{b^2} \]
[Out]
Time = 0.03 (sec) , antiderivative size = 31, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.300, Rules used = {3801, 3556, 30} \[ \int x \cot ^2(a+b x) \, dx=\frac {\log (\sin (a+b x))}{b^2}-\frac {x \cot (a+b x)}{b}-\frac {x^2}{2} \]
[In]
[Out]
Rule 30
Rule 3556
Rule 3801
Rubi steps \begin{align*} \text {integral}& = -\frac {x \cot (a+b x)}{b}+\frac {\int \cot (a+b x) \, dx}{b}-\int x \, dx \\ & = -\frac {x^2}{2}-\frac {x \cot (a+b x)}{b}+\frac {\log (\sin (a+b x))}{b^2} \\ \end{align*}
Time = 0.25 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.42 \[ \int x \cot ^2(a+b x) \, dx=-\frac {x^2}{2}-\frac {x \cot (a)}{b}+\frac {\log (\sin (a+b x))}{b^2}+\frac {x \csc (a) \csc (a+b x) \sin (b x)}{b} \]
[In]
[Out]
Time = 0.24 (sec) , antiderivative size = 40, normalized size of antiderivative = 1.29
method | result | size |
default | \(-\frac {x^{2}}{2}+\frac {-\left (b x +a \right ) \cot \left (b x +a \right )+\ln \left (\sin \left (b x +a \right )\right )+a \cot \left (b x +a \right )}{b^{2}}\) | \(40\) |
parallelrisch | \(\frac {-x^{2} b^{2}-2 b x \cot \left (b x +a \right )+2 \ln \left (\tan \left (b x +a \right )\right )-\ln \left (\sec \left (b x +a \right )^{2}\right )}{2 b^{2}}\) | \(45\) |
norman | \(\frac {-\frac {x}{b}-\frac {\tan \left (b x +a \right ) x^{2}}{2}}{\tan \left (b x +a \right )}+\frac {\ln \left (\tan \left (b x +a \right )\right )}{b^{2}}-\frac {\ln \left (1+\tan \left (b x +a \right )^{2}\right )}{2 b^{2}}\) | \(56\) |
risch | \(-\frac {x^{2}}{2}-\frac {2 i x}{b}-\frac {2 i a}{b^{2}}-\frac {2 i x}{b \left ({\mathrm e}^{2 i \left (b x +a \right )}-1\right )}+\frac {\ln \left ({\mathrm e}^{2 i \left (b x +a \right )}-1\right )}{b^{2}}\) | \(57\) |
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 75 vs. \(2 (29) = 58\).
Time = 0.25 (sec) , antiderivative size = 75, normalized size of antiderivative = 2.42 \[ \int x \cot ^2(a+b x) \, dx=-\frac {b^{2} x^{2} \sin \left (2 \, b x + 2 \, a\right ) + 2 \, b x \cos \left (2 \, b x + 2 \, a\right ) + 2 \, b x - \log \left (-\frac {1}{2} \, \cos \left (2 \, b x + 2 \, a\right ) + \frac {1}{2}\right ) \sin \left (2 \, b x + 2 \, a\right )}{2 \, b^{2} \sin \left (2 \, b x + 2 \, a\right )} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 65 vs. \(2 (26) = 52\).
Time = 0.21 (sec) , antiderivative size = 65, normalized size of antiderivative = 2.10 \[ \int x \cot ^2(a+b x) \, dx=\begin {cases} \tilde {\infty } x^{2} & \text {for}\: a = 0 \wedge b = 0 \\\frac {x^{2} \cot ^{2}{\left (a \right )}}{2} & \text {for}\: b = 0 \\\tilde {\infty } x^{2} & \text {for}\: a = - b x \\- \frac {x^{2}}{2} - \frac {x}{b \tan {\left (a + b x \right )}} - \frac {\log {\left (\tan ^{2}{\left (a + b x \right )} + 1 \right )}}{2 b^{2}} + \frac {\log {\left (\tan {\left (a + b x \right )} \right )}}{b^{2}} & \text {otherwise} \end {cases} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 269 vs. \(2 (29) = 58\).
Time = 0.36 (sec) , antiderivative size = 269, normalized size of antiderivative = 8.68 \[ \int x \cot ^2(a+b x) \, dx=\frac {2 \, {\left (b x + a + \frac {1}{\tan \left (b x + a\right )}\right )} a - \frac {{\left (b x + a\right )}^{2} \cos \left (2 \, b x + 2 \, a\right )^{2} + {\left (b x + a\right )}^{2} \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, {\left (b x + a\right )}^{2} \cos \left (2 \, b x + 2 \, a\right ) + {\left (b x + a\right )}^{2} - {\left (\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1\right )} \log \left (\cos \left (b x + a\right )^{2} + \sin \left (b x + a\right )^{2} + 2 \, \cos \left (b x + a\right ) + 1\right ) - {\left (\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1\right )} \log \left (\cos \left (b x + a\right )^{2} + \sin \left (b x + a\right )^{2} - 2 \, \cos \left (b x + a\right ) + 1\right ) + 4 \, {\left (b x + a\right )} \sin \left (2 \, b x + 2 \, a\right )}{\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1}}{2 \, b^{2}} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 1026 vs. \(2 (29) = 58\).
Time = 0.73 (sec) , antiderivative size = 1026, normalized size of antiderivative = 33.10 \[ \int x \cot ^2(a+b x) \, dx=\text {Too large to display} \]
[In]
[Out]
Time = 12.09 (sec) , antiderivative size = 54, normalized size of antiderivative = 1.74 \[ \int x \cot ^2(a+b x) \, dx=\frac {\ln \left ({\mathrm {e}}^{a\,2{}\mathrm {i}}\,{\mathrm {e}}^{b\,x\,2{}\mathrm {i}}-1\right )}{b^2}-\frac {x\,2{}\mathrm {i}}{b}-\frac {x^2}{2}-\frac {x\,2{}\mathrm {i}}{b\,\left ({\mathrm {e}}^{a\,2{}\mathrm {i}+b\,x\,2{}\mathrm {i}}-1\right )} \]
[In]
[Out]